<?php get_header(); ?>
<body class="portfolio-archive" data-ajaxloading data-smoothscrolling >
    <div class="pace">
        <div class="pace-activity"></div>
    </div>
    <div id="page">
        <nav class="navigation  navigation--mobile">
            <h2 class="accessibility">主手机导航</h2>
            <nav class="menu-header-menu-container">
                <ul id="wpgrade-main-nav-mobile" class="site-navigation site-navigation--main site-navigation--mobile">
                    <li  class="menu-item  current-menu-item">
                        <a href="<?php bloginfo('url'); ?>">网站首页</a>
                    </li>
                    <li class="menu-item menu-item-has-children">
                        <a href="<?php bloginfo('url'); ?>/product">作品画廊</a>
                        <ul class="sub-menu">
                            <?php wp_list_cats("child_of=" . get_category_root_id(3) . "&depth=0&hide_empty=0") ?>
                        </ul>
                    </li>
                    <li class="menu-item"><a href="<?php bloginfo('url'); ?>/designers">设计师</a>
                    </li>
                    <li class="menu-item"><a href="<?php bloginfo('url'); ?>/about">认识我们</a>
                    </li>
                    <li class="menu-item "><a href="http://www.3denjoy.com/" target="_blank">官方论坛</a></li>
                    <li class="menu-item"><a href="<?php bloginfo('url'); ?>/contact">联系我们</a></li>
                </ul>
            </nav>            
            <div class="nav-meta">
                <div class="sidebar--header">
                    <div id="text-2" class="widget widget--header widget_text">         
                        <div class="textwidget"></div>
                    </div>  
                </div>
                <div class="header__social-section">
                    <h4 class="widget__title">社交媒体</h4>     
                    <ul class="site-social-links">
                        <li class="site-social-links__social-link">
                            <a href="index.html#" target="_blank">
                                <i class="pixcode  pixcode--icon  icon-e-sina-weibo"></i>
                            </a>
                        </li>
                        <li class="site-social-links__social-link">
                            <a href="index.html#" target="_blank">
                                <i class="pixcode  pixcode--icon  icon-e-tqq"></i>
                            </a>
                        </li>
                        <li class="site-social-links__social-link">
                            <a href="index.html#" target="_blank">
                                <i class="pixcode  pixcode--icon  icon-e-weixin"></i>
                            </a>
                        </li>
                        <li class="site-social-links__social-link">
                            <a href="index.html#" target="_blank">
                                <i class="pixcode  pixcode--icon  icon-e-qq"></i>
                            </a>
                        </li>
                        <li class="site-social-links__social-link">
                            <a href="index.html#" target="_blank">
                                <i class="pixcode  pixcode--icon  icon-e-renren"></i>
                            </a>
                        </li>
                    </ul>
                </div>            
                <div class="site-info">
                    <p>2015 © 3-dage.com with love by <a href="" target="_blank">三维魔坊</a> Team</p>
                </div><!-- .site-info -->
            </div>
        </nav> 

        <div class="wrapper">
            <div class="header" data-smoothscrolling>
                <header class="site-header">
                    <div class="site-header__branding">
                        <div class="site-logo site-logo--image site-logo--image-2x">
                            <a class="site-home-link" href="" title="">
                                <img src="<?php bloginfo('template_url'); ?>/images/logo01.png" data-logo2x="<?php bloginfo('template_url'); ?>/images/logo01.png"  alt=""/>
                            </a>
                        </div>
                    </div>
                    <div class="site-navigation__trigger js-nav-trigger">
                        <span class="nav-icon"></span>
                    </div>
                    <div class="header__inner-wrap">
                        <div id="navigation" class="djax-updatable">
                            <nav class="menu-header-menu-container">
                                <ul id="wpgrade-main-nav-desktop" class="site-navigation site-navigation--main">
                                    <li class="menu-item--main current-menu-item">
                                        <a href="<?php bloginfo('url'); ?>" class="">网站首页</a>
                                    </li>
                                    <li class="menu-item--main menu-item--parent">
                                        <a href="<?php bloginfo('url'); ?>/product" class="">作品画廊</a>
                                        <ul class="site-navigation__sub-menu">
                                        <?php wp_list_cats("child_of=" . get_category_root_id(3) . "&depth=0&hide_empty=0") ?>
                                        </ul>
                                    </li>
                                    <li class="menu-item--main">
                                        <a href="<?php bloginfo('url'); ?>/designers" class="">设计师</a>
                                    </li>
                                    <li class="menu-item--main">
                                        <a href="<?php bloginfo('url'); ?>/about" class="">认识我们</a>
                                    </li>
                                    <li class="menu-item--main ">
                                        <a href="http://www.3denjoy.com/" target="_blank" class="">官方论坛</a>
                                    </li>
                                    <li class="menu-item--main ">
                                        <a href="<?php bloginfo('url'); ?>/contact" class="">联系我们</a>
                                    </li>
                                </ul>
                            </nav>          
                        </div>
                    </div>
                </header>

            	<div class="sidebar--header">
        		    <div id="text-2" class="widget widget--header widget_text">			
                        <div class="textwidget"></div>
		            </div>	
                </div>
                <footer id="colophon" class="site-footer" role="contentinfo">
                    <div class="header__social-section">
                        <h4 class="widget__title">社交媒体</h4>                
                        <ul class="site-social-links">
                            <li class="site-social-links__social-link">
                                <a href="index.html#" target="_blank">
                                    <i class="pixcode  pixcode--icon  icon-e-sina-weibo"></i>
                                </a>
                            </li>
                            <li class="site-social-links__social-link">
                                <a href="index.html#" target="_blank">
                                    <i class="pixcode  pixcode--icon  icon-e-tqq"></i>
                                </a>
                            </li>
                            <li class="site-social-links__social-link">
                                <a href="index.html#" target="_blank">
                                    <i class="pixcode  pixcode--icon  icon-e-weixin"></i>
                                </a>
                            </li>
                            <li class="site-social-links__social-link">
                                <a href="index.html#" target="_blank">
                                    <i class="pixcode  pixcode--icon  icon-e-qq"></i>
                                </a>
                            </li>
                            <li class="site-social-links__social-link">
                                <a href="index.html#" target="_blank">
                                    <i class="pixcode  pixcode--icon  icon-e-renren"></i>
                                </a>
                            </li>
                        </ul>
                    </div>
        
                    <div class="site-info text--right">
                        <p>2015 © 3-dage.com with love by <a href="" target="_blank">三维魔坊</a> Team</p>
                    </div><!-- .site-info -->
                </footer><!-- #colophon -->
            </div>
            <!-- .header -->
            
            <div id="main" class="content djax-updatable ">
	            <div class="mosaic__filter sticky-button">
                    <div class="filter__btn sticky-button__btn btn btn--large">
                        <i class="pixcode  pixcode--icon  icon-e-up-circled"></i>
                        <span>作品分类</span>
                        <ul>
                            <li class="mosaic__filter-item sticky-button-item" data-filter="practical">实用家居</li>
                            <li class="mosaic__filter-item sticky-button-item" data-filter="sculpture">人物雕塑</li>
                            <li class="mosaic__filter-item sticky-button-item" data-filter="building">建筑模型</li>
                            <li class="mosaic__filter-item sticky-button-item" data-filter="toy">玩具模型</li>
                            <li class="mosaic__filter-item sticky-button-item" data-filter="all">查看全部</li>
                        </ul>
                    </div>
                </div>

                <div class="mosaic " data-maxpages="0">
                    <?php query_posts('showposts=4'); ?>
                    <?php while (have_posts()) : the_post(); ?>
                    <div class="mosaic__item zan-a2 zan-a5 <?php
                                                    foreach((get_the_category()) as $category)
                                                    {
                                                    echo " ";
                                                    echo $category->category_nicename;
                                                    echo " ";
                                                    }
                                                ?> " >
                        <a href="<?php the_permalink(); ?>" class="image__item-link">
                            <div class="image__item-wrapper">
                                <?php
                                    $images =get_post_meta( $post->ID, 'tz');
                                    foreach ( $images as $image )
                                    {
                                        echo '<img class="js-lazy-load" src="" data-src="'.pods_image_url( $image, 'null' ).'" >';
                                    }
                                ?> 
                            </div>
                            <div class="image__item-meta image_item-meta--portfolio ">
                                <div class="image_item-table">
                                    <div class="image_item-cell image_item--block image_item-cell--top">
                                        <h4 class="image_item-title"><?php the_title() ?></h4>
                                        <span class="image_item-description"><?php the_excerpt() ?></span>
                                    </div>
                                    <div class="image_item-cell image_item--block image_item-cell--bottom">
                                        <div class="image_item-meta grid">
                                            <ul class="image_item-categories grid__item one-half">
                                                <li class="image_item-cat-icon">
                                                    <i class="icon-folder-open"></i>
                                                </li>
                                                <?php
                                                    foreach((get_the_category()) as $category)
                                                    {   
                                                        echo "<li class='image_item-category'>";
                                                        echo $category->cat_name;
                                                        echo "</li>";
                                                    }
                                                ?>
                                            </ul>
                                            <div class="pixlikes-box liked image_item-like-box likes-box grid__item one-half likes-box" data-id="331">
                                                <span class="like-link">
                                                   <i class="icon-e-heart"></i>
                                                </span>
                                                <div class="likes-text">
                                                    <span class="likes-count"><span class="zan-a1"></span></span> 喜欢   
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="zan-a4">
                                <?php wp_zan();?>
                            </div>
                        </a>
                    </div>
                    <?php endwhile;wp_reset_query();?>

                    <div class="mosaic__item js--is-loaded toy building practical sculpture mosaic__item--page-title">
                        <div class="image__item-link">
                            <div class="image__item-wrapper"></div>
                            <div class="image__item-meta">
                                <div class="image_item-table">
                                    <div class="image_item-cell">
                                        <h1>Dage - 作品展</h1>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    
                    <?php if (have_posts()) :$ashu_i=0;?> 
                    <?php while (have_posts()) : the_post();$ashu_i++;?>
                    <?php if($ashu_i>=5){?> 
                    <div class="mosaic__item zan-a2 zan-a5 <?php
                                                    foreach((get_the_category()) as $category)
                                                    {
                                                    echo " ";
                                                    echo $category->category_nicename;
                                                    echo " ";
                                                    }
                                                ?> ">
                        <a href="<?php the_permalink(); ?>" class="image__item-link">
                            <div class="image__item-wrapper">
                                <?php
                                    $images =get_post_meta( $post->ID, 'tz');
                                    foreach ( $images as $image )
                                    {
                                        echo '<img class="js-lazy-load" src="" data-src="'.pods_image_url( $image, 'null' ).'" >';
                                    }
                                ?> 
                            </div>
                            <div class="image__item-meta image_item-meta--portfolio">
                                <div class="image_item-table">
                                    <div class="image_item-cell image_item--block image_item-cell--top">
                                        <h4 class="image_item-title"><?php the_title() ?></h4>
                                        <span class="image_item-description"><?php the_excerpt() ?></span>
                                    </div>
                                    <div class="image_item-cell image_item--block image_item-cell--bottom">
                                        <div class="image_item-meta grid">
                                            <ul class="image_item-categories grid__item one-half">
                                                <li class="image_item-cat-icon">
                                                    <i class="icon-folder-open"></i>
                                                </li>
                                                
                                                <?php
                                                    foreach((get_the_category()) as $category)
                                                    {   
                                                        echo "<li class='image_item-category'>";
                                                        echo $category->cat_name;
                                                        echo "</li>";
                                                    }
                                                ?>

                                                
                                             
                                            </ul>
                                            <div class="pixlikes-box liked image_item-like-box likes-box grid__item one-half likes-box" data-id="331">
                                                <span class="like-link">
                                                   <i class="icon-e-heart"></i>
                                                </span>
                                                <div class="likes-text">
                                                    <span class="likes-count"><span class="zan-a1"></span></span> 喜欢   
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="zan-a4">
                                <?php wp_zan();?>
                            </div>
                        </a>
                    </div>
                    <?php }?>
                    <?php endwhile; endif; ?>
                </div>
                <!-- .mosaic -->
	        </div>
            <!-- .content -->        
        </div>
        <!-- .wrapper -->
    </div>
    <?php get_footer(); ?>
